const bcrypt = require('bcrypt')

const encrypt = async (password) => {
    return await bcrypt.hash(password, 10);
}

const decrypt = async (password, dbPassword) => {
    return await bcrypt.compare(password, dbPassword);
}

module.exports = {
    encrypt, decrypt
}